package com.springboot.repository;

import com.springboot.domain.BtPersonSkills;
import org.springframework.data.jpa.repository.JpaRepository;
import org.springframework.data.jpa.repository.Query;
import org.springframework.stereotype.Repository;

import java.util.List;

@Repository
public interface PersonSkillsRepository extends JpaRepository<BtPersonSkills, String>{

    @Query("select bts.skillId from com.springboot.domain.BtPersonSkills bts where bts.userId = ?1")
    List<Integer> findSkillsByUserId(String id);

    void deleteByUserId(String id);
}
